package com.entity.taskorder;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;

import java.time.LocalDateTime;

/**
 * 任务单主表实体类
 */
@ApiModel("任务单主表实体")
@Data
@NoArgsConstructor
@AllArgsConstructor
@TableName("task_orders")
public class TaskOrder {

    @ApiModelProperty(value = "主键，唯一标识每个任务单")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;


    @ApiModelProperty(value = "任务单单号，唯一标识每个任务单，不能为空")
    @TableField("task_order_number")
    private String taskOrderNumber;

    @ApiModelProperty(value = "客户公司ID，关联到客户公司表的主键")
    @TableField("customer_company_id")
    private Long customerCompanyId;

    @ApiModelProperty(value = "联系人ID")
    @TableField("contact_person_id")
    private Long contactPersonId;

    @ApiModelProperty(value = "商务负责人ID")
    @TableField("business_manager_id")
    private Long businessManagerId;

    @ApiModelProperty(value = "技术负责人ID")
    @TableField("technical_manager_id")
    private Long technicalManagerId;

    @ApiModelProperty(value = "往年经验")
    @TableField("past_experience")
    private String pastExperience;

    @ApiModelProperty(value = "技术支持内容")
    @TableField("support_content")
    private String supportContent;

    @ApiModelProperty(value = "技术支持方案")
    @TableField("support_plan")
    private String supportPlan;

    @ApiModelProperty(value = "要求完成天数")
    @TableField("required_days")
    private String requiredDays;

    @ApiModelProperty(value = "实际完成天数")
    @TableField("actual_days")
    private String actualDays;

    @ApiModelProperty(value = "任务批准人ID")
    @TableField("approver_id")
    private Long approverId;

    @ApiModelProperty(value = "任务核准人ID")
    @TableField("verifier_id")
    private Long verifierId;

    @ApiModelProperty(value = "状态: editing, confirmed, in_progress, completed")
    @TableField("status")
    private String status;

    @ApiModelProperty(value = "逻辑删除标志（1: 未删除，0: 已删除）")
    @TableField("is_deleted")
    private Integer isDeleted;

    @ApiModelProperty(value = "创建时间，默认为当前时间")
    @TableField(value = "create_time", fill = FieldFill.INSERT)
    private LocalDateTime createTime;

    @ApiModelProperty(value = "更新时间，每次更新时自动刷新")
    @TableField(value = "update_time", fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updateTime;

    @ApiModelProperty(value = "制表人（当前登录用户名）")
    @TableField("created_by")
    private String createdBy;

    @ApiModelProperty(value = "图片URL")
    @TableField("images_url")
    private String imagesUrl;
}